<?php

namespace App\Model;

use Illuminate\Database\Eloquent\Model;

/**
 * 数据库表sale_promotion的ORM
 * @author wuboheng
 */
class Sale_promotion extends Model
{
    protected $table = 'sale_promotion';

    protected $primaryKey = 'id';

    public $timestamps = true;

    public function findGoods()
    {
        return $this->belongsTo('App\Model\Goods', 'gid');
    }

    public function findGoodsPrice()
    {
        return $this->belongsTo('App\Model\Gprice', 'pid');
    }

    public function findSort()
    {
        return $this->belongsTo('App\Model\Gprice', 'sid');
    }
}
